<!--
 * @Descripttion: 
 * @version: 
 * @Author: EayCome
 * @Date: 2021-02-10 14:44:54
 * @LastEditors: EayCome
 * @LastEditTime: 2021-02-10 14:54:01
-->
<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>字符串测试</title>
    <script src="index.js"></script>
</head>

<body>
    <script>
        // 声明字符串
        let str = 'iloveyou';
        let str2 = 'lol';
        let str3 = 'Eaycome';
        // 测试
        // 测试字符串翻转
        console.log(reverseString(str));
        // 测试是否为回文
        console.log(palindrome(str2));
        // 测试字符串截断
        console.log(truncate(str3, 3));
    </script>
</body>

</html>